<div class="layui-header">
    <a href="{:url('index/index')}"><div class="layui-logo">tp6.0.2自动生成代码及文件</div></a>
    <ul class="layui-nav layui-layout-left">
        <li class="layui-nav-item"><a href="{:url('index/modular_page')}">创建模块</a></li>
        <li class="layui-nav-item"><a href="{:url('index/common_page')}">公共函数</a></li>
        <li class="layui-nav-item"><a href="{:url('index/middleware_page')}">中间件</a></li>
        <li class="layui-nav-item"><a href="{:url('index/event_page')}">事件</a></li>
        <li class="layui-nav-item"><a href="{:url('index/validata_page')}">生成验证器</a></li>
        <li class="layui-nav-item">
            <a href="javascript:;">模型</a>
            <dl class="layui-nav-child">
                <dd><a href="{:url('index/create_model_files')}">创建模型文件</a></dd>
                <dd><a href="{:url('index/create_model_code')}">创建模型代码</a></dd>
            </dl>
        </li>
        <li class="layui-nav-item">
            <a href="javascript:;">分层</a>
            <dl class="layui-nav-child">
                <dd><a href="{:url('index/layered_files')}">创建分层文件</a></dd>
                <dd><a href="{:url('index/layered_code')}">创建分层代码</a></dd>
            </dl>
        </li>
        <li class="layui-nav-item">
            <a href="javascript:;">控制器</a>
            <dl class="layui-nav-child">
                <dd><a href="{:url('index/basis_controller')}">基础&资源控制器</a></dd>
                <dd><a href="{:url('index/empty_controller')}">空控制器</a></dd>
            </dl>
        </li>
        <li class="layui-nav-item">
            <a href="javascript:;">视图</a>
            <dl class="layui-nav-child">
                <dd><a href="{:url('index/form1')}">编辑表单生成</a></dd>
                <dd><a href="{:url('index/table1')}">管理表格生成</a></dd>
            </dl>
        </li>
    </ul>
</div>
<script>
    layui.use('element', function(){
        var element = layui.element; //导航的hover效果、二级菜单等功能，需要依赖element模块
        //监听导航点击
        element.on('nav(demo)', function(elem){
            //console.log(elem)
            layer.msg(elem.text());
        });
    });
</script>
